package com.visual.core.service;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.IService;
import com.visual.core.domain.BladeVisualCategory;
import com.visual.core.filter.BladeVisualCategorySearchContext;
import org.springframework.data.domain.Page;

import java.util.Collection;
import java.util.List;
import java.util.Map;

/**
 * 实体[BladeVisualCategory] 服务对象接口
 */
public interface IBladeVisualCategoryService extends IService<BladeVisualCategory> {

    boolean create(BladeVisualCategory et);
    void createBatch(List<BladeVisualCategory> list);
    boolean update(BladeVisualCategory et);
    void updateBatch(List<BladeVisualCategory> list);
    boolean remove(Long key);
    void removeBatch(Collection<Long> idList);
    BladeVisualCategory get(Long key);
    BladeVisualCategory getDraft(BladeVisualCategory et);
    boolean checkKey(BladeVisualCategory et);
    boolean save(BladeVisualCategory et);
    void saveBatch(List<BladeVisualCategory> list);
    Page<BladeVisualCategory> searchDefault(BladeVisualCategorySearchContext context);
    /**
     *自定义查询SQL
     * @param sql  select * from table where id =#{et.param}
     * @param param 参数列表  param.put("param","1");
     * @return select * from table where id = '1'
     */
    List<JSONObject> select(String sql, Map param);
    /**
     *自定义SQL
     * @param sql  update table  set name ='test' where id =#{et.param}
     * @param param 参数列表  param.put("param","1");
     * @return     update table  set name ='test' where id = '1'
     */
    boolean execute(String sql, Map param);

}


